Skip to content

fix(cli): improve programmatic reliability for chat, auth, search, and image size - #124

Closed
hopelynd wants to merge 4 commits into
mainfrom
fix/programmatic-cli-errors
Closed

fix(cli): improve programmatic reliability for chat, auth, search, and image size#124
hopelynd wants to merge 4 commits into
mainfrom
fix/programmatic-cli-errors

Conversation

@hopelynd

Copy link
Copy Markdown
Collaborator

Summary

  • Add shared enable_thinking helpers in core and use them in text chat and auth login: non-streaming requests default to enable_thinking: false, with a one-shot retry when the API requires a different value (true, false, or omit).
  • Improve WebSearch UX: detect MCP-not-activated 404 errors and append an activation hint with a deep link to the MCP marketplace page.
  • Accept OpenAI-style WxH image sizes (e.g. 1024x1024), normalize to W*H, and reject unknown --size values locally with USAGE.
  • Update e2e expectations and add unit tests for the new thinking and WebSearch hint logic.

Test plan

  • vp test packages/core/tests/thinking.test.ts
  • vp test packages/commands/tests/search-web-activate-hint.test.ts
  • vp test packages/commands/tests/e2e/auth.e2e.test.ts (targeted login cases)
  • vp check
  • vp test (full suite)
  • Manual: bl text chat --dry-run --output json (non-stream request includes enable_thinking: false)
  • Manual: bl search web when WebSearch MCP is not activated (hint includes marketplace URL)
  • Manual: bl image generate --size 1024x1024 accepts OpenAI-style size format

hopelynd added 4 commits July 24, 2026 10:56
Normalize 1024x1024 / 1024×1024 to width*height before the API call, and reject unknown ratios locally with USAGE instead of a server 400.
…s false

Non-streaming chat no longer forces enable_thinking=false, which breaks
thinking-only models. Retry once with false only when the server demands it.
@hopelynd hopelynd closed this Jul 27, 2026
@hopelynd
hopelynd deleted the fix/programmatic-cli-errors branch July 28, 2026 01:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant